package cn.edu.neu.vmmigeval.evaluation;

import cn.edu.neu.vmmigeval.cloud.entity.DataCenter;
import cn.edu.neu.vmmigeval.cloud.entity.DataCenterBroker;

/**
 * The measure to monitor and collect parameters from the current data center.
 *
 * @author yfwz100
 */
public interface Measure {

    /**
     * The name of the measure.
     *
     * @return the name.
     */
    default String getName() {
        return getClass().getName();
    }

    /**
     * Monitor metrics by the processing cycle.
     *
     * @param clock the clock cycle.
     * @param dcb the broker of VMs.
     * @param dc the data center to process.
     */
    void process(int clock, DataCenterBroker dcb, DataCenter dc);

    /**
     * Get the collected value.
     *
     * @return the collected value.
     */
    double getValue();

}
